<extend name="Layout/ins_page" />
<block name="content">
	{:W('PageHeader/simple',array('name'=>'新建待办事项'))}
	<div class="sub-frame gray">
		<form method='post' id="form_data" name="form_data" enctype="multipart/form-data"   >
			<input type="hidden" id="ajax" name="ajax" value="0">
			<input type="hidden" id="status" name="status" value="1">
			<input type="hidden" id="opmode" name="opmode" value="add">
			<div class="layui-form-item">
				<label class="layui-form-label" for="name">标题*：</label>
				<div class="layui-input-block">
					<input value="" class="layui-input" type="text" id="name" name="name" check="required" info="请输入标题">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label" for="end_date">结束：</label>
				<div class="layui-input-block">
					<input  type="text" id="end_date" name="end_date" readonly="readonly" class="layui-input input-date" value="" readonly="readonly">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label" >优先级：</label>
				<div class="layui-input-block col-16 x-select">
					<select name="priority" class="layui-input">
						<option value="">请选择优先级</option>
						<option value="3">高</option>
						<option value="2">普通</option>
						<option value="1">低</option>
					</select>
				</div>
			</div>
			<div class=""></div>
			<div class="layui-form-item">
				<label class="layui-form-label" for="name">附件：</label>
				<div class="layui-input-block">
					{:W('FileUpload/add')}
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label" for="name">内容：</label>
				<div class="layui-input-block">
					<textarea  class="editor" id="content" name="content" style="width:100%;height:200px;"></textarea>
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label" for="name"></label>
				<div class="layui-input-block">
					<input class="btn" type="button" value="保存" id="btn_save">
					<input  class="btn btn-cancel" type="button" value="取消" onclick="go_return_url();">
				</div>
			</div>
		</form>
	</div>
</block>
<block name="js">
	<script type="text/javascript">
		layui.use(['global', 'uploader'], function() {
			var $ = layui.jquery;
			
			$('#btn_save').on('click', function() {
				send_form('form_data', "{:U('save')}", '', function() {
				});
			});
			$("#btn_add").on('click', function() {
				winopen("{:U('add')}", 560, 470);
			});
		});

	</script>
</block>